home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 27.zip / BS1 part 27 / RefokickV1.4.adf / Relokick.DOC next >
Text File  |  1978-12-13  |  6KB  |  142 lines

  1.  
  2.             -* Relokick v1.4 - (C) 1993 Galahad of Dual Crew *-
  3.            -----------------------------------------------------
  4.  
  5.             Relokick instructions/CACHE controller source code
  6.             --------------------------------------------------
  7.  
  8. Hello ALL fellow Amiga owners.  Why another version of Relokick I hear you
  9. ask, when the first version did a pretty good job??  Well simply this.  The
  10. original version did not have the ability to disable CPU CACHES!!
  11.  
  12. And yes, this new version now supports the MC68020 processor CPU CACHE.  
  13.  
  14.                                 Why bother?
  15.                                 -----------
  16. Despite how good the first version was, there were plenty of application and
  17. game software that still refused to work because the CPU CACHE was left on.
  18. The most common problem with games software was bad programming of loaders.
  19. Many game loaders were simply running to fast and thus could never get the
  20. file/track it needed.  So for this reason, I have built in a CPU CACHE
  21. controller.
  22.  
  23.                               Extra functions
  24.                               ---------------
  25. While the Kickstart screen is being displayed, the mouse buttons will perform
  26. the following functions.
  27.  
  28. Left Mouse button  - Disable CPU CACHES (Signified by copper flash)
  29. Right Mouse button - NTSC Switch (Only for owners of ECS equipped machines!)
  30.  
  31. I put the NTSC switch in simply because it is easy to implement and that
  32. because of Kickstart 3's Boot Control menu giving you the very same function.
  33.  
  34. It seemed prudent that I put that option in.  Unfortunately, I could not put
  35. a toggle in there (i.e. Pressing the Right Mouse button would switch between
  36. PAL/NTSC) simply because there was not enough room.  In fact the coders of
  37. Amigaland out there will even see that the code I used is plasterd all over
  38. the Kickstart!!  (It was that cramped, so much so, I nearly thought I could
  39. not get it in there!!! - Oooer!!)
  40.  
  41. Obviously, if you dont't want to disable the CPU CACHES, then don't press the
  42. left mouse button.
  43.  
  44. Special thanks must goto Taste/Binary Emotions for discovering how to turn
  45. the bloody CACHES off in the first place.  Cheers dude!
  46.  
  47. For those that are coders amoung you, here is the source to turn off the CPU
  48. CACHES:
  49.  
  50. start:
  51.     lea    routine(pc),a0    ; locate start of program into a0
  52.     move.l     a0,$80        ; for relocatable purposes
  53.     trap    #0        ; Call the trap!
  54.     rts            ; Return
  55.  
  56. routine:
  57.     dc.w    $4e7a,$0002    ; MOVEC CACR,d0
  58.     bclr    #0,d0        ; Bitclear d0
  59.     dc.w    $4e7b,$0002    ; MOVEC d0,CACR
  60.     rte            ; Return exception!
  61.  
  62. The reason why there are dc.w statements instead of MOVEC statements is
  63. simple...... the basic 68000 processor does not have these instructions, they
  64. are exclusive to the 68020 and above!!  So by using the dc.w statements, you
  65. can still code the routine on a basic A500 etc.
  66.  
  67. You MUST go into supervisor mode to actually switch off the CPU CACHES, hence
  68. the use of a trap.  Incidentally, to turn the CPU CACHES back on, simply
  69. replace the bclr with a bset instruction.
  70.  
  71. For those that don't know, the CACR register is called the CACHE CONTROL
  72. REGISTER! (Simplicity!).
  73.  
  74. Please note.  Allthough you can assemble this routine on a basic A500 or any
  75. Amiga that has less than a 68020, if you attempt to run the assembled
  76. routines, the Amiga will crash, simply cos you are trying to execute commands
  77. that the Amiga does not understand.  So, before you all go out releasing your
  78. own versions of CACHE switchers, remember to put code in there to check what
  79. type of CPU is present, otherwise there are gonna be a lot of moaning people
  80. I think!!
  81.  
  82.                                   Regards
  83.                                   -------
  84.  
  85. Regards goto the following friends, dudes and people that deserve a greet:
  86.  
  87. Red Devil, Skol, Ice, Black Cat, Xanadu, Taste, Hydlide, Parodius, Pazza,
  88. Shagratt, Torch, mUB, DATA, Echo, Deadbeat, Steve, John (Tom Sheply),
  89. Dreadnought, Mr. 'lamey' Brownstone, Clairvoyant ( I will come and see ya! ), 
  90. Everyone in Lsd, Everyone in Scoopex, Everyone in Anthrox, Everyone in Dual
  91. Crew, Everyone in Ministry UK Division (N.O.M.A.D - Sorry for not crediting
  92. you when I borrowed your loader for BC KID!), CU AMIGA (For actually having
  93. the bottle to release the first version in the first place, I'm sure that
  94. it breaks every copyright rule in the book, but Commodore seem to be turning
  95. a blind eye.... We hope!!), Kelly Sumner - Commodore UK (Keep up the good
  96. work, and hey, don't let that DSP be too long before we see it!!), Gremlin
  97. Graphics + Electronic Arts + Ocean Software Ltd. (For supporting the A1200
  98. NOW, you have my respect) and....... Commodore Amiga Inc. and everyone who
  99. has played a part in getting the machine where it is today.
  100.  
  101. But the biggest greet goes to ANYONE who has supported the Amiga and who has
  102. purchased an A1200/A4000 Amiga.  We can all help in ensuring the Amiga's
  103. future, 60,000 people so far 17/3/93 have helped make that a reality.  For
  104. all those that are thinking about getting one, don't think, just buy the
  105. bloody thing...... YOU WILL NOT REGRET IT!!
  106.  
  107. But my biggest regard goes to Atari, its nice to see that you still act the
  108. way you always have.... BLIND!!  Get some new PR people, get some new
  109. marketing people, and then, and only then will the Falcon succeed, until
  110. then, why not rename it the DODO..... It just seems more apt!!!
  111.  
  112.  
  113.                                  End note
  114.                                  --------
  115.  
  116. This program is free to copy, there are no restrictions on who copies it.  PD
  117. Libraries are not to charge any more than their normal charge for disks (i.e.
  118. don't go charging any more for it, just cos its a bit more special than most
  119. other stuff!!).  If I see ANY PD libraries charging an extortionate amount
  120. for this program, I will NEVER update this program again!!  
  121.  
  122. Please leave this doc on this disk, DO NOT REMOVE IT!!
  123.  
  124.  
  125. Catch you later Bill & Ted..... Galahad/Dual Crew 1993
  126.  
  127.  
  128. Commodore Amiga is a trademark of Commodore Business Machines.
  129. Falcon is a trademark of Atari, but could Atari afford to trademark the
  130. Falcon???
  131.  
  132. Joke
  133. ----
  134. Q. What does every Atari ST and Atari Falcon owner want to be when they
  135. GROW up?
  136.  
  137. A. An Amiga owner!!!
  138.  
  139.  
  140. Dual Crew
  141.      There are always two points of view........
  142.